package cn.com.callback;
import groovy.json.*;
import groovy.swing.impl.DefaultAction;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.RequestDispatcher;
import cn.com.elite.EliteBean;
import java.security.MessageDigest;
import java.sql.ResultSet;
import java.text.SimpleDateFormat;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import com.wisdge.dataservice.Result;
import java.util.Map;
import java.util.Date;
import java.util.HashMap;

import org.json.JSONObject;
import org.json.JSONArray;
import org.json.JSONException;

import cn.com.elite.Util;
import cn.com.kh.getProperty;
import cn.com.kh.KHUtil;

/**
 *
 * @Title: job_SmsSend
 * @Description: 华盛短信定时发送 job
 * @author: Chieh
 * @date 2021-07-28 11:43:00
 *
 */

public class job_SmsSend implements CallBackInvoke{
	private static final Log log=LogFactory.getLog(job_SmsSend.class);

	public void doCallBack(EliteBean eliteBean,String callBack,Map map,String body) {

		log.debug("-------------------------start job_SmsSend 开始调用-----------------");

		Map<String, String> headMap = new HashMap<String, String>();
		headMap.put("Content-Type", "application/json");
		//获取配置参数
		String sysurl = getProperty.get("crmurl");//配置本地接口地址
		String sysur3 = getProperty.get("crmurl");//配置本地接口地址
		String sysur4 = getProperty.get("crmurl");//配置本地接口地址

		//华盛 调度内部短信发送接口执行
		sysurl = sysurl+"api_SmsSend";
		sysur3 = sysur3+"api_Consultant_monitoring_data"; //顾问大屏监控
		sysur4 = sysur4+"aipHSTchatRequestUp"; //调网聊渠道 brand 数据更新 channel link

		try {
			Util.doHttpPostUseHead(sysurl,"{}","UTF-8",100000,0,headMap);//华盛 调度内部短信发送接口执行
		} catch (Exception e) {
			log.error("调度内部短信发送 接口处理异常" + e.getMessage());
		}

		try {
			Util.doHttpPostUseHead(sysur3,"{}","UTF-8",100000,0,headMap);//顾问大屏监控
		} catch (Exception e) {
			log.error("顾问大屏监控 接口处理异常" + e.getMessage());
		}

		try {
			Util.doHttpPostUseHead(sysur4,"{}","UTF-8",100000,0,headMap);	//调网聊渠道 brand 数据更新 channel link
		} catch (Exception e) {
			log.error("调网聊渠道 brand 数据更新 channel link 接口处理异常" + e.getMessage());
		}


	}
}